
#include <stdio.h>
#include <system/application.h>
#include <graphics/sprite.h>
#include <maths/vector2.h>
#include <maths/vector3.h>
#include <vector>
#include <graphics/mesh_instance.h>
#include <graphics/vita/texture_vita.h>
#include <graphics/model.h>

#include "GameState.h"
#include "MarkerLostState.h"



MarkerLostState::MarkerLostState(const abfw::Platform& platform)
{
	mFont = new abfw::Font();
	mFont->Load("comic_sans", platform);
}

MarkerLostState::~MarkerLostState()
{
}

GameStates::State MarkerLostState::Update() 
{

	if (mARCardFound[0] == true)
	{
		//-- Return the play state if the first marker is found
		return GameStates::PLAYSTATE;
	}

	return GameStates::MARKERLOSTSTATE;
}

void MarkerLostState::Draw2D(abfw::SpriteRenderer* render, abfw::Matrix44 Projection) 
{

	if(mFont)
	{
		mFont->RenderText(render, abfw::Vector3(850.0f, 510.0f, -0.9f), 1.0f, 0xffffffff, abfw::TJ_LEFT, "FPS: %.1f", mFps);
		mFont->RenderText(render, abfw::Vector3(320.0f, 242.0f, -0.9f), 1.0f, 0xffffffff, abfw::TJ_LEFT, "Base Is Out Of View!");
	}
	
}
void MarkerLostState::Draw3D(abfw::Renderer3D* render, abfw::Colour defaultColour) 
{
	
}
